package com.example.demo.pojos;

import javax.persistence.*;
import java.sql.Date;
import java.util.List;
import java.util.Objects;

@Entity
public class Client {
    private int clientId;
    private String clientName;
    private String clientZl;
    private String clientSyz;
    private String clientSmzq;
    private String clientSource;
    private Date clientOpentime;
    private Date clientEndtime;
    private String clientDx;
    private String clientTzts;
    private Date clientDay;
    private Integer clientYb;
    private String clientYx;
    private String clientGh;
    private List<Contact> lxr;
    private List<Xsjhinfo> xsjh;
    private List<Khxqinfo> khxq;
    private List<Jjfainfo> jjfa;
    private List<Jzgxinfo> jzgx;
    private List<Bjinfo> bj;
    private List<Bjmxinfo> bjmx;
    private List<Order> htdd;
    private List<Cashbackplan> hkjh;
    private List<Cashbackrecord> hkjl;
    private List<Invoicing> kp;
    private List<Show> gh;
    private List<Serve> fw;
    private List<Complain> ts;
    private List<Fixreceive> wxjj;

    @Id
    @Column(name = "client_id", nullable = false)
    public int getClientId() {
        return clientId;
    }

    public void setClientId(int clientId) {
        this.clientId = clientId;
    }

    @Basic
    @Column(name = "client_name", nullable = true, length = 30)
    public String getClientName() {
        return clientName;
    }

    public void setClientName(String clientName) {
        this.clientName = clientName;
    }

    @Basic
    @Column(name = "client_zl", nullable = true, length = 20)
    public String getClientZl() {
        return clientZl;
    }

    public void setClientZl(String clientZl) {
        this.clientZl = clientZl;
    }

    @Basic
    @Column(name = "client_syz", nullable = true, length = 20)
    public String getClientSyz() {
        return clientSyz;
    }

    public void setClientSyz(String clientSyz) {
        this.clientSyz = clientSyz;
    }

    @Basic
    @Column(name = "client_smzq", nullable = true, length = 20)
    public String getClientSmzq() {
        return clientSmzq;
    }

    public void setClientSmzq(String clientSmzq) {
        this.clientSmzq = clientSmzq;
    }

    @Basic
    @Column(name = "client_source", nullable = true, length = 20)
    public String getClientSource() {
        return clientSource;
    }

    public void setClientSource(String clientSource) {
        this.clientSource = clientSource;
    }

    @Basic
    @Column(name = "client_opentime", nullable = true)
    public Date getClientOpentime() {
        return clientOpentime;
    }

    public void setClientOpentime(Date clientOpentime) {
        this.clientOpentime = clientOpentime;
    }

    @Basic
    @Column(name = "client_endtime", nullable = true)
    public Date getClientEndtime() {
        return clientEndtime;
    }

    public void setClientEndtime(Date clientEndtime) {
        this.clientEndtime = clientEndtime;
    }

    @Basic
    @Column(name = "client_dx", nullable = true, length = 30)
    public String getClientDx() {
        return clientDx;
    }

    public void setClientDx(String clientDx) {
        this.clientDx = clientDx;
    }

    @Basic
    @Column(name = "client_tzts", nullable = true, length = 20)
    public String getClientTzts() {
        return clientTzts;
    }

    public void setClientTzts(String clientTzts) {
        this.clientTzts = clientTzts;
    }

    @Basic
    @Column(name = "client_day", nullable = true)
    public Date getClientDay() {
        return clientDay;
    }

    public void setClientDay(Date clientDay) {
        this.clientDay = clientDay;
    }

    @Basic
    @Column(name = "client_yb", nullable = true)
    public Integer getClientYb() {
        return clientYb;
    }

    public void setClientYb(Integer clientYb) {
        this.clientYb = clientYb;
    }

    @Basic
    @Column(name = "client_yx", nullable = true, length = 20)
    public String getClientYx() {
        return clientYx;
    }

    public void setClientYx(String clientYx) {
        this.clientYx = clientYx;
    }

    @Basic
    @Column(name = "client_gh", nullable = true, length = 30)
    public String getClientGh() {
        return clientGh;
    }

    public void setClientGh(String clientGh) {
        this.clientGh = clientGh;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Client client = (Client) o;
        return clientId == client.clientId &&
                Objects.equals(clientName, client.clientName) &&
                Objects.equals(clientZl, client.clientZl) &&
                Objects.equals(clientSyz, client.clientSyz) &&
                Objects.equals(clientSmzq, client.clientSmzq) &&
                Objects.equals(clientSource, client.clientSource) &&
                Objects.equals(clientOpentime, client.clientOpentime) &&
                Objects.equals(clientEndtime, client.clientEndtime) &&
                Objects.equals(clientDx, client.clientDx) &&
                Objects.equals(clientTzts, client.clientTzts) &&
                Objects.equals(clientDay, client.clientDay) &&
                Objects.equals(clientYb, client.clientYb) &&
                Objects.equals(clientYx, client.clientYx) &&
                Objects.equals(clientGh, client.clientGh);
    }

    @Override
    public int hashCode() {
        return Objects.hash(clientId, clientName, clientZl, clientSyz, clientSmzq, clientSource, clientOpentime, clientEndtime, clientDx, clientTzts, clientDay, clientYb, clientYx, clientGh);
    }

    @OneToMany(mappedBy = "kh")
    public List<Contact> getLxr() {
        return lxr;
    }

    public void setLxr(List<Contact> lxr) {
        this.lxr = lxr;
    }

    @OneToMany(mappedBy = "kh")
    public List<Xsjhinfo> getXsjh() {
        return xsjh;
    }

    public void setXsjh(List<Xsjhinfo> xsjh) {
        this.xsjh = xsjh;
    }

    @OneToMany(mappedBy = "kh")
    public List<Khxqinfo> getKhxq() {
        return khxq;
    }

    public void setKhxq(List<Khxqinfo> khxq) {
        this.khxq = khxq;
    }

    @OneToMany(mappedBy = "kh")
    public List<Jjfainfo> getJjfa() {
        return jjfa;
    }

    public void setJjfa(List<Jjfainfo> jjfa) {
        this.jjfa = jjfa;
    }

    @OneToMany(mappedBy = "kh")
    public List<Jzgxinfo> getJzgx() {
        return jzgx;
    }

    public void setJzgx(List<Jzgxinfo> jzgx) {
        this.jzgx = jzgx;
    }

    @OneToMany(mappedBy = "kh")
    public List<Bjinfo> getBj() {
        return bj;
    }

    public void setBj(List<Bjinfo> bj) {
        this.bj = bj;
    }

    @OneToMany(mappedBy = "kh")
    public List<Bjmxinfo> getBjmx() {
        return bjmx;
    }

    public void setBjmx(List<Bjmxinfo> bjmx) {
        this.bjmx = bjmx;
    }

    @OneToMany(mappedBy = "kh")
    public List<Order> getHtdd() {
        return htdd;
    }

    public void setHtdd(List<Order> htdd) {
        this.htdd = htdd;
    }

    @OneToMany(mappedBy = "kh")
    public List<Cashbackplan> getHkjh() {
        return hkjh;
    }

    public void setHkjh(List<Cashbackplan> hkjh) {
        this.hkjh = hkjh;
    }

    @OneToMany(mappedBy = "kh")
    public List<Cashbackrecord> getHkjl() {
        return hkjl;
    }

    public void setHkjl(List<Cashbackrecord> hkjl) {
        this.hkjl = hkjl;
    }

    @OneToMany(mappedBy = "kh")
    public List<Invoicing> getKp() {
        return kp;
    }

    public void setKp(List<Invoicing> kp) {
        this.kp = kp;
    }

    @OneToMany(mappedBy = "kh")
    public List<Show> getGh() {
        return gh;
    }

    public void setGh(List<Show> gh) {
        this.gh = gh;
    }

    @OneToMany(mappedBy = "kh")
    public List<Serve> getFw() {
        return fw;
    }

    public void setFw(List<Serve> fw) {
        this.fw = fw;
    }

    @OneToMany(mappedBy = "kh")
    public List<Complain> getTs() {
        return ts;
    }

    public void setTs(List<Complain> ts) {
        this.ts = ts;
    }

    @OneToMany(mappedBy = "kh")
    public List<Fixreceive> getWxjj() {
        return wxjj;
    }

    public void setWxjj(List<Fixreceive> wxjj) {
        this.wxjj = wxjj;
    }
}
